package com.atguigu.encapsolation.one;

public class Employee {
    //属性私有化
    private static String company;//公司名
    private String name;
    private double salary;
    private boolean marry;

    //快捷键Alt+ Insert，部分同学可能需要同时按Fn
    public static String getCompany() {
        return company;
    }

    public static void setCompany(String company) {
        Employee.company = company;
//        this.company = company;//错误
    }

    public boolean isMarry() {
        return marry;
    }

    public void setMarry(boolean marry) {
        this.marry = marry;
    }

    public double getSalary() {
        return salary;
    }

    public void setSalary(double salary) {
        this.salary = salary;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
